package com.javatest.springbootelastic.bean;

import lombok.Data;
import org.springframework.data.elasticsearch.annotations.Document;

/**
 * @author lzy
 * @version v1.0 Create DateTime: 2019/4/24 13:22
 *     <p>加上了@Document注解之后，默认情况下这个实体中所有的属性都会被建立索引、并且分词
 */
@Data
@Document(indexName = "atguigu", type = "book")
public class Book {
  private Integer id;
  private String bookName;
  private String author;
}
